home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / fortran / f2c_src.zip / F2C / LIBF77 / R_NINT.C < prev    next >
Encoding:
C/C++ Source or Header  |  1991-06-10  |  130 b   |  11 lines

  1. #include "f2c.h"
  2.  
  3. double r_nint(x)
  4. real *x;
  5. {
  6. double floor();
  7.  
  8. return( (*x)>=0 ?
  9.     floor(*x + .5) : -floor(.5 - *x) );
  10. }
  11.